# Contributor: Henrik Riomar <henrik.riomar@gmail.com>
# Maintainer:
pkgname=jitterentropy-rngd
pkgver=1.1.0
pkgrel=0
pkgdesc="CPU Jitter RNG Daemon"
url="http://www.chronox.de/jent.html"
arch="all"
license="BSD-3-Clause OR GPL-2.0-Only"
makedepends="linux-headers"
options="!check" # no test suite
subpackages="$pkgname-doc $pkgname-openrc"
source="jitterentropy-rngd-$pkgver.tar.gz::https://github.com/smuellerDD/jitterentropy-rngd/archive/v$pkgver.tar.gz
	$pkgname.initd
	"

build() {
	make
}

package() {
	make DESTDIR="$pkgdir" PREFIX=/usr install

	install -m755 -D "$srcdir"/$pkgname.initd \
		"$pkgdir"/etc/init.d/$pkgname

	rm -rf "$pkgdir"/usr/lib/systemd
}

sha512sums="32835475b604e502caaab9b0d1cd9fe2920c126a27841669f6cf9c717094bfd4c11feab0f9f706ee4cf4caeedf26ced7039075499a3faaf41830c72968544646  jitterentropy-rngd-1.1.0.tar.gz
5903286b2bec9aedd7f05c7e95ac464709479f802467ac749a51794074ee15b819582c6b6993520ee3a9acb505994683edb739b45932b55d16e53bb42df8cc39  jitterentropy-rngd.initd"
